
/* 第一个投票活动样式 */

/* 活动头部样式 */
.campaign-header {
    background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
    border-radius: 12px;
    color: white;
    padding: 2rem;
    margin-bottom: 2rem;
    position: relative;
    overflow: hidden;
}

.campaign-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23ffffff' fill-opacity='0.1'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
    opacity: 0.4;
}

.campaign-header .campaign-title {
    font-size: 2.2rem;
    font-weight: 700;
    margin-bottom: 1rem;
    position: relative;
}

.campaign-header .campaign-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
    position: relative;
}

.campaign-header .campaign-meta-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.campaign-header .campaign-description {
    font-size: 1.1rem;
    margin-bottom: 1.5rem;
    max-width: 800px;
    position: relative;
}

.campaign-header .campaign-stats {
    display: flex;
    gap: 2rem;
    margin-bottom: 1.5rem;
    position: relative;
}

.campaign-header .campaign-stats .campaign-stat {
    text-align: center;
}

.campaign-header .campaign-stats .stat-value {
    font-size: 1.8rem;
    font-weight: 700;
    margin-bottom: 0.25rem;
}

.campaign-header .campaign-stats .stat-label {
    font-size: 0.9rem;
    opacity: 0.9;
}

.campaign-header .campaign-stats .campaign-actions {
    display: flex;
    gap: 1rem;
    position: relative;
}

/* 文章列表样式 */
.section-title {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1.5rem;
    padding-bottom: 0.75rem;
    border-bottom: 2px solid var(--primary-light);
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-title i {
    color: var(--primary);
}

.articles-container {
    background-color: white;
    border-radius: 12px;
    box-shadow: var(--shadow);
    overflow: hidden;
    margin-bottom: 2rem;
}

.articles-container .articles-header {
    padding: 1rem 1.5rem;
    background-color: var(--primary-light);
    border-bottom: 1px solid var(--border);
}

.articles-container .articles-header .articles-filters {
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.articles-container .articles-header .articles-filters .view-controls {
    display: flex;
    gap: 0.5rem;
}

.articles-container .articles-header .articles-filters .view-controls .view-btn {
    background-color: white;
    border: 1px solid var(--border);
    border-radius: 6px;
    padding: 0.3rem 0.75rem;
    color: var(--gray);
    transition: all 0.2s;
}

.articles-container .articles-header .articles-filters .view-controls .view-btn:hover, .view-btn.active {
    background-color: var(--primary);
    color: white;
    border-color: var(--primary);
}

.articles-container .articles-header .articles-filters .filter-sort {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.articles-container .articles-header .articles-filters  .filter-label {
    font-weight: 500;
    color: var(--dark);
}

/* 列表视图样式 */
.articles-container .articles-list-view .article-item {
    padding: 1.5rem;
    border-bottom: 1px solid var(--border);
    display: flex;
    gap: 1.5rem;
    transition: transform 0.2s, box-shadow 0.2s;
}

.articles-container .articles-list-view .article-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.articles-container .articles-list-view .article-item:last-child {
    border-bottom: none;
}

.articles-container .articles-list-view .article-item .article-image {
    width: 120px;
    height: 120px;
    border-radius: 8px;
    object-fit: cover;
    flex-shrink: 0;
}

.articles-container .articles-list-view .article-item .article-content {
    flex: 1;
}

/* 网格视图样式 */
.articles-container   .articles-grid-view {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
    gap: 1.5rem;
    padding: 1.5rem;
}

.articles-container   .articles-grid-view .article-item {
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
    flex-direction: column;
}

.articles-container   .articles-grid-view .article-item:hover {
    transform: translateY(-5px);
    box-shadow: var(--shadow-hover);
}

.articles-container  .articles-grid-view .article-item .article-image {
    width: 100%;
    height: 180px;
    object-fit: cover;
}

.articles-container  .articles-grid-view .article-item .article-content {
    padding: 1rem;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.articles-container  .articles-grid-view .article-item .article-rank {
    margin: -1rem -1rem 1rem -1rem;
    width: auto;
    height: auto;
    border-radius: 0;
    padding: 0.25rem 1rem;
    justify-content: flex-start;
}

/* 卡片视图样式 */
.articles-container   .articles-card-view {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    padding: 1.5rem;
}

.articles-container   .articles-card-view .article-item {
    border: 1px solid var(--border);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: transform 0.2s, box-shadow 0.2s;
    display: flex;
}

.articles-container   .articles-card-view .article-item:hover {
    transform: translateY(-3px);
    box-shadow: var(--shadow-hover);
}

.articles-container   .articles-card-view .article-item .article-image {
    width: 30%;
    object-fit: cover;
}

.articles-container  .articles-card-view .article-item .article-content {
    width: 70%;
    padding: 1.5rem;
}

@media (max-width: 768px) {
    .articles-container   .articles-card-view .article-item {
        flex-direction: column;
    }

    .articles-container   .articles-card-view .article-item .article-image,
    .articles-container   .articles-card-view .article-item .article-content {
        width: 100%;
    }

    .articles-container   .articles-card-view .article-item .article-image {
        height: 200px;
    }
}

/* 通用文章样式 */
.articles-container .article-item   .article-rank {
    width: 40px;
    height: 40px;
    border-radius: 8px;
    background-color: var(--primary-light);
    color: var(--primary);
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 1.2rem;
    flex-shrink: 0;
}

.articles-container .article-item   .article-rank.top-1 {
    background-color: #fff3cd;
    color: #fd7e14;
}

.articles-container .article-item    .article-rank.top-2 {
    background-color: #e9ecef;
    color: #6c757d;
}

.articles-container .article-item   .article-rank.top-3 {
    background-color: #fff3cd;
    color: #d97706;
}

.articles-container .article-item .article-content  .article-title {
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.5rem;
    color: var(--dark);
    text-decoration: none;
    transition: color 0.2s;
}

.articles-container .article-item .article-content .article-title:hover {
    color: var(--primary);
}

.articles-container .article-item .article-content .article-meta {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    margin-bottom: 0.75rem;
    font-size: 0.9rem;
    color: var(--gray);
}

.articles-container .article-item .article-content .article-author {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.articles-container .article-item .article-content .author-avatar {
    width: 24px;
    height: 24px;
    border-radius: 50%;
    object-fit: cover;
}

.articles-container .article-item .article-content .article-excerpt {
    color: var(--gray);
    font-size: 0.95rem;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.articles-container .article-item .article-content .article-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
    margin-bottom: 1rem;
}

.articles-container .article-item .article-content .article-tag {
    background-color: var(--primary-light);
    color: var(--primary);
    padding: 0.2rem 0.75rem;
    border-radius: 20px;
    font-size: 0.8rem;
    text-decoration: none;
}

.articles-container .article-item .article-content  .article-actions {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: auto;
}

.articles-container .article-item .article-content .votes-count {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-weight: 600;
    color: var(--primary);
}

.articles-container .article-item .article-content  .vote-btn {
    background-color: var(--primary);
    color: white;
    border: none;
    padding: 0.4rem 1.2rem;
    border-radius: 6px;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: background-color 0.2s;
}

.articles-container .article-item .article-content  .vote-btn:hover {
    background-color: var(--primary-dark);
}

.articles-container .article-item .article-content .vote-btn.voted {
    background-color: var(--success);
}

/* 投票进度样式 */
.articles-container .article-item .article-content .voting-progress {
    margin-top: 0.5rem;
    height: 8px;
    background-color: #e9ecef;
    border-radius: 4px;
    overflow: hidden;
}

.articles-container .article-item .article-content .progress-bar {
    height: 100%;
    background-color: var(--primary);
    border-radius: 4px;
    transition: width 0.5s ease;
}

/* 模态框样式 */
.modal-content {
    border-radius: 12px;
    border: none;
    box-shadow: var(--shadow-hover);
}

.modal-content .modal-header {
    border-bottom: 1px solid var(--border);
    padding: 1.25rem 1.5rem;
}

.modal-content  .modal-title {
    font-size: 1.25rem;
    font-weight: 600;
    color: var(--dark);
}

.modal-content .modal-body {
    padding: 1.5rem;
}

.modal-content  .modal-footer {
    border-top: 1px solid var(--border);
    padding: 1rem 1.5rem;
}

.modal-content  .modal-body .my-articles-list {
    max-height: 400px;
    overflow-y: auto;
    margin-bottom: 1rem;
}

.modal-content   .modal-body.my-article-option {
    padding: 1rem;
    border: 1px solid var(--border);
    border-radius: 8px;
    margin-bottom: 0.75rem;
    cursor: pointer;
    transition: all 0.2s;
}

.modal-content  .modal-body .my-article-option:hover {
    border-color: var(--primary);
    background-color: var(--primary-light);
}

.modal-content  .modal-body .my-article-option.selected {
    border-color: var(--primary);
    background-color: var(--primary-light);
    position: relative;
}

.modal-content  .modal-body .my-article-option.selected::after {
    content: '\f00c';
    font-family: 'Font Awesome 6 Free';
    font-weight: 900;
    color: var(--primary);
    position: absolute;
    top: 1rem;
    right: 1rem;
}

.modal-content  .modal-body .no-articles-message {
    text-align: center;
    padding: 2rem;
    color: var(--gray);
}

.modal-content   .modal-body .no-articles-message i {
    font-size: 3rem;
    margin-bottom: 1rem;
    opacity: 0.5;
}

/* 分页样式 */
.pagination-container {
    display: flex;
    justify-content: center;
    margin: 2rem 0;
}

.pagination-container .pagination .page-link {
    color: var(--primary);
    border: 1px solid var(--border);
    margin: 0 0.25rem;
    border-radius: 6px;
    transition: all 0.2s;
}

.pagination-container .pagination .page-link:hover {
    color: var(--primary-dark);
    background-color: var(--primary-light);
    border-color: var(--primary);
}

.pagination-container .pagination .page-link.active {
    background-color: var(--primary);
    border-color: var(--primary);
    color: white;
}

/* 响应式设计 */
@media (max-width: 992px) {
    .campaign-header .campaign-stats {
        flex-wrap: wrap;
    }
}

@media (max-width: 768px) {

    .campaign-header  .campaign-title {
        font-size: 1.8rem;
    }

    .campaign-header .campaign-stats  .campaign-actions {
        flex-direction: column;
        align-items: stretch;
    }

    .articles-container .article-item .article-content  .article-actions {
        flex-direction: column;
        align-items: stretch;
        gap: 1rem;
    }

    .articles-container .article-item .article-content  .vote-btn {
        width: 100%;
        justify-content: center;
    }

    .articles-container .articles-header .articles-filters  .filter-sort {
        flex-wrap: wrap;
    }
}

